<script type="text/javascript">
    function showFocus(emt) {
        var chList = emt.parentNode.childNodes;
        for (var c = 0; c < chList.length; c++) {
            var cEmt = chList[c];
            if (cEmt == emt) {
                cEmt.className = "current";
            } else {
                cEmt.className = "hide";
            }
        }
        var topDiv = document.getElementById("top_div");
        var divList = topDiv.childNodes;
        var tid = emt.tid || emt.attributes['tid'].value;
        for (var i = 0; i < divList.length; i++) {
            var item = divList[i];
            if (item.nodeName.toUpperCase() == "DIV") {
                if (item.id == "title-" + tid) {
                    item.style.display = "";
                } else if (item.className == "oferta_content") {
                    item.style.display = "none";
                }
            }
        }
    }
</script>
<div id="main_container">
    <div class="top_bar">
        <div class="top_search">
            <div class="search_text"><a href="#">搜索</a></div>
            <input type="text" class="search_input" name="search"/>
            <input type="image" src="/images/search.gif" class="search_bt"/>
        </div>
    </div>
    <div id="header">
        <div id="logo">
            <a href="index.html"><img src="/images/logo.gif" alt="" title="" border="0" width="237" height="140"/></a>
        </div>
        <div class="oferte_content">
            <div class="top_divider"><img src="/images/header_divider.png" alt="" title="" width="1" height="164"/>
            </div>
            <div class="oferta" id="top_div">
                <foreach name="tjList" item="tItem" key="seq_key">
                    <if condition=" $seq_key eq 0 ">
                        <div class="oferta_content" id="title-{$tItem.oid}">
                            <img src="/images/laptop.png" width="94" height="92" border="0" class="oferta_img"/>

                            <div class="oferta_details">
                                <div class="oferta_title">{$tItem.name}</div>
                                <div class="oferta_text">
                                    {$tItem.book_brief}
                                </div>
                                <a href="details.html" class="details"> 详情 </a>
                            </div>
                        </div>
                        <else/>
                        <div class="oferta_content" id="title-{$tItem.oid}" style="display: none">
                            <img src="/images/laptop.png" width="94" height="92" border="0" class="oferta_img"/>

                            <div class="oferta_details">
                                <div class="oferta_title">{$tItem.name}</div>
                                <div class="oferta_text">
                                    {$tItem.book_brief}
                                </div>
                                <a href="details.html" class="details"> 详情 </a>
                            </div>
                        </div>
                    </if>
                </foreach>
                <div class="oferta_pagination">
                    <foreach name="tjList" item="tItem" key="seq_key">
                        <if condition=" $seq_key eq 0 ">
                            <span class="current" onmouseover="showFocus(this);" onclick="showFocus(this);"
                                  tid="{$tItem.oid}">{$seq_key}</span>
                            <else/>
                            <span class="hide" onmouseover="showFocus(this);" onclick="showFocus(this);"
                                  tid="{$tItem.oid}">{$seq_key}</span>
                        </if>
                    </foreach>
                </div>
            </div>
            <div class="top_divider"><img src="/images/header_divider.png" alt="" title="" width="1" height="164"/>
            </div>
        </div>
        <!-- end of oferte_content-->
    </div>